home *** CD-ROM | disk | FTP | other *** search
/ System Booster / System Booster.iso / SYS / s / REXX.lha / scman.wrx < prev    next >
Text File  |  1995-05-01  |  1KB  |  54 lines

  1. /*
  2.  * WRITE macro to obtain SAS/C library help on current function
  3.  *
  4.  * Place the cursor on or behind an SAS/C library function
  5.  * and the corresponding AmigaGuide page will be popped on
  6.  * screen.
  7.  *
  8.  * written 20/09/1993 by Lars Hanke
  9.  * © 1993 by MGR - Software, Asgard
  10.  *
  11.  * default keymapping:
  12.  *            KEY 'control help' DoRexx "scman.wrx" 1;
  13.  *
  14.  * initialization:
  15.  *   set "helppath" to where your helps are to be found
  16.  *
  17.  */
  18.  
  19.  
  20. /* set helppath to where you placed the SAS/C AmigaGuides
  21.    by default they are placed in SC:Help/                  */
  22.  
  23. helppath = "XDOC:guides/help/"
  24.  
  25. if ~show('P',WRITE) then say "This is only useful with WRITE running"
  26.  
  27. address 'WRITE'
  28. options results
  29.  
  30. 'VERSIONCHECK 40000 "SCMan.wrx"'
  31. IF RC~=0 THEN DO
  32.   exit 10
  33. END
  34.  
  35. 'GETVAR "_CurrentWord"'
  36. item = RESULT
  37.  
  38. if item = "RESULT" then
  39. do
  40.   'GETVAR "_XPos"'
  41.   x=RESULT
  42.   'GETVAR "_YPos"'
  43.   y=RESULT
  44.   'LASTWORD'
  45.   'GETVAR "_CurrentWord"'
  46.   item = RESULT
  47.   'GOTO' x y
  48. end
  49.  
  50. item=compress(item,"*[]()")
  51.  
  52. address 'COMMAND'
  53. 'run >nil: amigaguide '||helppath||'sc_lib.guide doc' item||'()'
  54.